package com.apes.scm.rbac.comparator;

import com.apes.scm.rbac.model.Operation;

import java.util.Comparator;

public class OperationsComparator implements Comparator<Operation> {

    public int compare(Operation operation1,Operation operation2 ) {
        int result = operation1.getMenu().getSortCode().compareTo(operation2.getMenu().getSortCode());
        if(result == 0) {
            result = 1;
        }
        return result;
    }
}
